<!DOCTYPE html>
<html>

<head>
    <title>{$info.company}</title>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="target-densitydpi=device-dpi, width=400px, user-scalable=no" />
    <include file="Share:meta" />
<!--     <link rel="stylesheet" href="../Public/bootstrap/css/bootstrap.css">
    <link rel="stylesheet" href="../Public/font-awesome-4.4.0/css/font-awesome.css">
    <script type="text/javascript" src="../Public/plugins/jQuery/jquery-1.11.1.min.js"></script>
    <script type="text/javascript" src="../Public/bootstrap/js/bootstrap.min.js"></script>
    <link rel="stylesheet" type="text/css" href="../Public/css/bizcard.css?v=20161006002"> -->
    <script type="text/javascript">
    </script>
    <style type="text/css">
    .modifyaccount {
        padding-top: 50px;
        color: #000;
    }
    
    .modifyaccount .header {
        position: fixed;
        top: 0px;
        left: 0px;
        width: 100%;
        background-color: #595757;
        height: 50px;
        display: block;
        z-index: 100;
    }
    
    .modifyaccount .header>div>a {
        line-height: 50px;
        font-size: 16px;
    }
    
    .modifyaccount .header>div>button {
        height: 50px;
        background-color: #595757;
        box-shadow: none;
        border: 0px;
        font-size: 16px;
    }
    
    .modifyaccount .form-horizontal .form-group {
        border-bottom: 1px solid #cececf;
        padding-bottom: 0px;
        margin-bottom: 0px;
    }
    
    .modifyaccount .form-horizontal .form-group .control-label {
        line-height: 30px;
        color: #595656;
        border-right: 1px solid #cececf;
        height: 50px;
        margin-bottom: 0px;
        line-height: 50px;
        font-weight: normal;
    }
    
    .modifyaccount .form-horizontal .form-group .form-control {
        box-shadow: none;
        margin-top: 5px;
        font-size: 18px;
        height: 40px;
    }
    
    .companyintro {
        margin-top: 5px;
        width: 100%;
        height: 400px;
    }
    
    .imgRow {
        border-bottom: 1px solid #ccc;
        padding-bottom: 10px;
        padding-top: 10px;
    }
    
    .imgList {
        max-width: 98%;
        border: 1px solid #ccc;
        padding: 2px;
    }
    </style>
</head>

<body class="modifypage">
    <div class="container-fluid container modifyaccount" style="background-color:#fff;">
        <div class="header">
            <div class="col-xs-3 textcenter">
                <a href="/bizcard/account.html">返回</a>
            </div>
            <div class="col-xs-6 textcenter">
                <a href="#">公司信息修改</a>
            </div>
            <div class="col-xs-3 textcenter">
                <a href="/bizcard/intro/hash/{$info.hash}">预览</a>
            </div>
        </div>
        <volist name="list" id="vo">
            <form action="" method="POST" class="form-horizontal" role="form" enctype="multipart/form-data">
                <input type="hidden" name="fid" id="input" class="form-control" value="{$vo.fid}" required="required" pattern="" title="">
                <div class="form-group">
                    <div class="imgRow">
                        <div class="col-xs-4">
                            <img class="imgList companyupload" src="{$vo.path}">
                        </div>
                        <div class="col-xs-5">
                            排序：
                            <br>
                            <input type="text" name="orderby" id="" class="form-control" value="{$vo.orderby}" required="required">
                        </div>
                        <div class="col-xs-3">
                            <button type="submit" class="btn btn-info">保存</button>
                            <br>
                            <button type="button" class="btn btn-error" style="margin-top: 10px;" onclick="del('{$vo.fid}')">删除</button>
                        </div>
                        <div class="clearfix">
                        </div>
                    </div>
                </div>
            </form>
        </volist>
        <form action="" method="POST" class="form-horizontal" role="form" enctype="multipart/form-data">
            <div id="companyfilesgroup">
            </div>
            <div class="form-group">
                <div class="col-xs-6 textcenter">
                    <button type="button" class="btn btn-default" id="addfilesbutton" style="margin:5px;" onclick="addfiles();">增加图片栏位</button>
                </div>

                <div class="col-xs-6">
                    <button type="submit" class="btn btn-primary" style="margin:5px;">保存公司简介</button>
                </div>
            </div>
             <div class="form-group">
                <label for="companyintro" class="col-xs-4 control-label textleft" style="border-right: 0px;">视频地址：</label>
                <div class="col-xs-8">
                    <input type="text" name="video_url" id="inputEventCode" class="form-control" value="{$info.video_url}" placeholder=""  autocomplete="off">
                </div>
            </div>
            <div class="form-group">
                <label for="companyintro" class="col-xs-12 control-label textleft" style="border-right: 0px;">公司简介：</label>
            </div>
           
            <div class="form-group">
                <div class="col-xs-12">
                    <textarea class="companyintro" name="introduction_simple">{$info.introduction_simple}</textarea>
                </div>
            </div>
            <div class="form-group">
                <label for="companyintro" class="col-xs-12 control-label textcenter" style="border-right: 0px;"><button type="submit" class="btn btn-primary">保存公司简介</button></label>
            </div>
        </form>
    </div>
    <script type="text/javascript">
    function addfiles() {
        if ($('.companyupload').length >= 9) {
            $('#addfilesbutton').hide();
            return;
        }
        $('<div class="form-group">' +
            '<label for="company" class="col-xs-4 control-label np textcenter">形象展示图</label>' +
            '<div class="col-xs-8">' +
            '<input type="file" name="company[]" class="form-control companyupload" title="">' +
            '</div>' +
            '</div>').appendTo("#companyfilesgroup");

        if ($('.companyupload').length >= 9) {
            $('#addfilesbutton').hide();
            return;
        }
    }
    addfiles();

    $(".imgList").click(function() {
        if (confirm('确认删除此图片吗')) {
            alert(1);
        }
    });

    function del(id){
        if(confirm('确定删除这张图片?')){window.location.href='/bizcard/modifyCompanyInfo/delete/'+id;return false;}else{return false;}
    }

    </script>
</body>

</html>
